package com.frog.service.friend.model;

import com.frog.service.friend.page.PageInfo;
import lombok.*;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

/**
 * 分页查询返回记录
 *
 * @param <T>
 */
@Getter
@Setter
@NoArgsConstructor
@AllArgsConstructor
public class PageFriendListRespModel<T> implements Serializable {
    private List<T> findRespVoList = new ArrayList<>();
    private long findRespVoListSize = 0;
    private long toTalSize = 0;
    private String pageSet = "";
    private String ext1;


    public PageFriendListRespModel(PageInfo<T> pageInfo) {
        if (pageInfo == null) return;
        findRespVoList = pageInfo.getList();
        findRespVoListSize = pageInfo.getSize();
        toTalSize = pageInfo.getPages();
        pageSet = pageInfo.getPageSet();
    }
}
